import http from "./request"

// 获取菜单列表
export const getListApi = async () => {
    return await http.get('/api/menu/list', null)
}

// 获取上级菜单列表
export const getParentListApi = async () => {
    return await http.get('/api/menu/parent', null)
}

// 新增菜单
export const addMenuApi = async params => {
    return await http.post('/api/menu', params)
}

// 编辑菜单
export const editMenuApi = async params => {
    return await http.put('/api/menu', params)
}

// 删除菜单
export const deleteMenuApi = async params => {
    return await http.delete('/api/menu', params)
}